const commentService = require("../service/comment.service")

class CommentController {
    async upload(ctx, next) {
        const {
            content,
            momentId
        } = ctx.request.body
        const {
            id
        } = ctx.user
        console.log(ctx.user);
        const result = await commentService.update(content, momentId, id)
        ctx.body = {
            code: 200,
            message: '评论成功',
            result
        }
    }
}

module.exports = new CommentController()